//
//  GlobalMethod+Function.h
//  MexicoLoan
//
//  Created by WXP on 2025/2/24.
//

#import "GlobalMethod.h"

NS_ASSUME_NONNULL_BEGIN

@interface GlobalMethod (Function)

#pragma mark - 认证跳转
+ (void)jumpToAuthWithAuthInfo:(NSString *)authInfo;

#pragma mark - 按顺序取出每个认证步骤奖励的金钱
+ (NSArray *)getMoneyAuthStep:(NSDictionary *)response;

#pragma mark - 风控埋点
+ (void)addRiskControlWithType:(NSString *)type startTime:(NSString *)startTime endTime:(NSString *)endTime;


#pragma mark - 显示金额
+ (NSString *)showMoney:(NSString *)moneyStr;

#pragma mark - double 转 string
+ (NSString *)showDoubleToStr:(double)number;

#pragma mark - 提示
+ (void)showAlert:(NSString *)strAlert;

#pragma mark - 收键盘
+ (void)endEditing;





#pragma mark - 判断是不是接口：登录/验证码/保存认证信息/修改银行卡，这几个接口code为500也要弹窗提醒返回的message
+ (BOOL)checkWhetherShowMessageWithUrl:(NSString *)url;

#pragma mark - 线程
+ (void)asynthicBlock:(void (^)(void))block;
+ (void)mainQueueBlock:(void (^)(void))block;

#pragma mark - 获取当前时间戳
+ (NSString *)getTimeStamp;
+ (NSString *)getTimeStampMillisecond;

#pragma mark - 压缩图片
+ (NSData *)compressImage:(UIImage *)image toMaxSize:(NSUInteger)maxSizeKB;

#pragma mark - 校验邮箱格式
+ (BOOL)isValidEmail:(NSString *)email;

#pragma mark - 某一动作一天只执行一次
+ (void)executeOncePerDayWithKey:(NSString *)key block:(void (^)(void))block;

#pragma mark - 打点
+ (void)hitPointWithPageName:(NSString *)pageName action:(NSString *)action extInfo:(NSDictionary * _Nullable)extInfo;

+ (void)addADJEventWithToken:(NSString *)token phone:(NSString *)phone userId:(NSString *)userId;

#pragma mark - 用户详细行为埋点
+ (void)buryPointWithPageName:(NSString *)pageName featureName:(NSString *)featureName action:(NSString *)action type:(NSString *)type;

@end

NS_ASSUME_NONNULL_END
